package com.example.taluo.logic;

import com.example.taluo.entity.dto.gamedto.PlayerState;

/*** @Author supersaiya
 * @Description 判断游戏是否胜利

 * @Date 2025/2/18 17:07

 * @Version 1.0*/
public class VictoryConditionChecker {
    public boolean checkVictory(PlayerState playerA, PlayerState playerB) {
        // 基础胜利条件
        if (playerA.getLife() <= 0 || playerB.getLife() <= 0) {
            return true;
        }
        // 其他胜利条件
//        if (hasConsecutiveWins(playerA, 5)) {
//            return true;
//        }
        return false;
    }

    //其它胜利条件
//    private boolean hasConsecutiveWins(PlayerState player, int requiredWins) {
//        return player.getConsecutiveWins() >= requiredWins;
//    }
}